package git.soulbgm.pojo;

import git.soulbgm.common.annotation.IdBuild;
import git.soulbgm.common.enumerate.IdType;
import lombok.Data;

import javax.persistence.Id;
import java.io.Serializable;

/**
 * 菜单表
 *
 * @author SoulBGM
 * @version V1.0
 * @date 2019-09-23 00:13:29
 */
@Data
public class Menu implements Serializable {

    private static final long serialVersionUID = 5366946102418822734L;
    /**
     * 主键
     */
    @Id
    @IdBuild(IdType.JDBC)
    private Integer id;

    /**
     * 菜单访问URL的匹配规则
     */
    private String url;

    /**
     * 菜单访问的页面
     */
    private String path;

    /**
     * 菜单名称
     */
    private String name;

    /**
     * 图标地址
     */
    private String icon;

    /**
     * 权限字符串，menu例子：user:*, button例子：user:create,user:update,user:delete,user:view
     */
    private String permission;


    /**
     * 父菜单id 没有为0
     */
    private Integer parentId;

}